{"ast":null,"code":"import _defineProperty from \"/Users/poppie/Desktop/development/messenger/app/frontend/node_modules/@babel/runtime/helpers/esm/defineProperty.js\";\nimport { initZoomMotion } from '../../style/motion';\nimport { genComponentStyleHook, mergeToken, PresetColors } from '../../theme/internal';\nimport { resetComponent } from '../../style';\nimport getArrowStyle, { MAX_VERTICAL_CONTENT_RADIUS } from '../../style/placementArrow';\nvar generatorTooltipPresetColor = function generatorTooltipPresetColor(token) {\n  var componentCls = token.componentCls;\n  return PresetColors.reduce(function (previousValue, currentValue) {\n    var _previousValue$$conc;\n    var lightColor = token[\"\".concat(currentValue, \"-6\")];\n    previousValue[\"&\".concat(componentCls, \"-\").concat(currentValue)] = (_previousValue$$conc = {}, _defineProperty(_previousValue$$conc, \"\".concat(componentCls, \"-inner\"), {\n      backgroundColor: lightColor\n    }), _defineProperty(_previousValue$$conc, \"\".concat(componentCls, \"-arrow\"), {\n      '--antd-arrow-background-color': lightColor\n    }), _previousValue$$conc);\n    return previousValue;\n  }, {});\n};\nvar genTooltipStyle = function genTooltipStyle(token) {\n  var _Object$assign;\n  var componentCls = token.componentCls,\n    tooltipMaxWidth = token.tooltipMaxWidth,\n    tooltipColor = token.tooltipColor,\n    tooltipBg = token.tooltipBg,\n    tooltipBorderRadius = token.tooltipBorderRadius,\n    zIndexPopup = token.zIndexPopup,\n    controlHeight = token.controlHeight,\n    boxShadowSecondary = token.boxShadowSecondary,\n    paddingSM = token.paddingSM,\n    paddingXS = token.paddingXS,\n    tooltipRadiusOuter = token.tooltipRadiusOuter;\n  return [_defineProperty({}, componentCls, Object.assign(Object.assign(Object.assign(Object.assign({}, resetComponent(token)), (_Object$assign = {\n    position: 'absolute',\n    zIndex: zIndexPopup,\n    display: 'block',\n    '&': [{\n      width: 'max-content'\n    }, {\n      width: 'intrinsic'\n    }],\n    maxWidth: tooltipMaxWidth,\n    visibility: 'visible',\n    '&-hidden': {\n      display: 'none'\n    },\n    '--antd-arrow-background-color': tooltipBg\n  }, _defineProperty(_Object$assign, \"\".concat(componentCls, \"-inner\"), {\n    minWidth: controlHeight,\n    minHeight: controlHeight,\n    padding: \"\".concat(paddingSM / 2, \"px \").concat(paddingXS, \"px\"),\n    color: tooltipColor,\n    textAlign: 'start',\n    textDecoration: 'none',\n    wordWrap: 'break-word',\n    backgroundColor: tooltipBg,\n    borderRadius: tooltipBorderRadius,\n    boxShadow: boxShadowSecondary\n  }), _defineProperty(_Object$assign, [\"&-placement-left\", \"&-placement-leftTop\", \"&-placement-leftBottom\", \"&-placement-right\", \"&-placement-rightTop\", \"&-placement-rightBottom\"].join(','), _defineProperty({}, \"\".concat(componentCls, \"-inner\"), {\n    borderRadius: tooltipBorderRadius > MAX_VERTICAL_CONTENT_RADIUS ? MAX_VERTICAL_CONTENT_RADIUS : tooltipBorderRadius\n  })), _defineProperty(_Object$assign, \"\".concat(componentCls, \"-content\"), {\n    position: 'relative'\n  }), _Object$assign)), generatorTooltipPresetColor(token)), {\n    // RTL\n    '&-rtl': {\n      direction: 'rtl'\n    }\n  })),\n  // Arrow Style\n  getArrowStyle(mergeToken(token, {\n    borderRadiusOuter: tooltipRadiusOuter\n  }), {\n    colorBg: 'var(--antd-arrow-background-color)',\n    showArrowCls: '',\n    contentRadius: tooltipBorderRadius,\n    limitVerticalRadius: true\n  }), // Pure Render\n  _defineProperty({}, \"\".concat(componentCls, \"-pure\"), {\n    position: 'relative',\n    maxWidth: 'none'\n  })];\n};\n// ============================== Export ==============================\nexport default (function (prefixCls, injectStyle) {\n  var useOriginHook = genComponentStyleHook('Tooltip', function (token) {\n    // Popover use Tooltip as internal component. We do not need to handle this.\n    if (injectStyle === false) {\n      return [];\n    }\n    var borderRadius = token.borderRadius,\n      colorTextLightSolid = token.colorTextLightSolid,\n      colorBgDefault = token.colorBgDefault,\n      borderRadiusOuter = token.borderRadiusOuter;\n    var TooltipToken = mergeToken(token, {\n      // default variables\n      tooltipMaxWidth: 250,\n      tooltipColor: colorTextLightSolid,\n      tooltipBorderRadius: borderRadius,\n      tooltipBg: colorBgDefault,\n      tooltipRadiusOuter: borderRadiusOuter > 4 ? 4 : borderRadiusOuter\n    });\n    return [genTooltipStyle(TooltipToken), initZoomMotion(token, 'zoom-big-fast')];\n  }, function (_ref) {\n    var zIndexPopupBase = _ref.zIndexPopupBase,\n      colorBgSpotlight = _ref.colorBgSpotlight;\n    return {\n      zIndexPopup: zIndexPopupBase + 70,\n      colorBgDefault: colorBgSpotlight\n    };\n  });\n  return useOriginHook(prefixCls);\n});","map":{"version":3,"names":["initZoomMotion","genComponentStyleHook","mergeToken","PresetColors","resetComponent","getArrowStyle","MAX_VERTICAL_CONTENT_RADIUS","generatorTooltipPresetColor","token","componentCls","reduce","previousValue","currentValue","lightColor","backgroundColor","genTooltipStyle","tooltipMaxWidth","tooltipColor","tooltipBg","tooltipBorderRadius","zIndexPopup","controlHeight","boxShadowSecondary","paddingSM","paddingXS","tooltipRadiusOuter","Object","assign","position","zIndex","display","width","maxWidth","visibility","minWidth","minHeight","padding","color","textAlign","textDecoration","wordWrap","borderRadius","boxShadow","join","direction","borderRadiusOuter","colorBg","showArrowCls","contentRadius","limitVerticalRadius","prefixCls","injectStyle","useOriginHook","colorTextLightSolid","colorBgDefault","TooltipToken","_ref","zIndexPopupBase","colorBgSpotlight"],"sources":["/Users/poppie/Desktop/development/messenger/app/frontend/node_modules/antd/es/tooltip/style/index.js"],"sourcesContent":["import { initZoomMotion } from '../../style/motion';\nimport { genComponentStyleHook, mergeToken, PresetColors } from '../../theme/internal';\nimport { resetComponent } from '../../style';\nimport getArrowStyle, { MAX_VERTICAL_CONTENT_RADIUS } from '../../style/placementArrow';\nconst generatorTooltipPresetColor = token => {\n  const {\n    componentCls\n  } = token;\n  return PresetColors.reduce((previousValue, currentValue) => {\n    const lightColor = token[`${currentValue}-6`];\n    previousValue[`&${componentCls}-${currentValue}`] = {\n      [`${componentCls}-inner`]: {\n        backgroundColor: lightColor\n      },\n      [`${componentCls}-arrow`]: {\n        '--antd-arrow-background-color': lightColor\n      }\n    };\n    return previousValue;\n  }, {});\n};\nconst genTooltipStyle = token => {\n  const {\n    componentCls,\n    // ant-tooltip\n    tooltipMaxWidth,\n    tooltipColor,\n    tooltipBg,\n    tooltipBorderRadius,\n    zIndexPopup,\n    controlHeight,\n    boxShadowSecondary,\n    paddingSM,\n    paddingXS,\n    tooltipRadiusOuter\n  } = token;\n  return [{\n    [componentCls]: Object.assign(Object.assign(Object.assign(Object.assign({}, resetComponent(token)), {\n      position: 'absolute',\n      zIndex: zIndexPopup,\n      display: 'block',\n      '&': [{\n        width: 'max-content'\n      }, {\n        width: 'intrinsic'\n      }],\n      maxWidth: tooltipMaxWidth,\n      visibility: 'visible',\n      '&-hidden': {\n        display: 'none'\n      },\n      '--antd-arrow-background-color': tooltipBg,\n      // Wrapper for the tooltip content\n      [`${componentCls}-inner`]: {\n        minWidth: controlHeight,\n        minHeight: controlHeight,\n        padding: `${paddingSM / 2}px ${paddingXS}px`,\n        color: tooltipColor,\n        textAlign: 'start',\n        textDecoration: 'none',\n        wordWrap: 'break-word',\n        backgroundColor: tooltipBg,\n        borderRadius: tooltipBorderRadius,\n        boxShadow: boxShadowSecondary\n      },\n      // Limit left and right placement radius\n      [[`&-placement-left`, `&-placement-leftTop`, `&-placement-leftBottom`, `&-placement-right`, `&-placement-rightTop`, `&-placement-rightBottom`].join(',')]: {\n        [`${componentCls}-inner`]: {\n          borderRadius: tooltipBorderRadius > MAX_VERTICAL_CONTENT_RADIUS ? MAX_VERTICAL_CONTENT_RADIUS : tooltipBorderRadius\n        }\n      },\n      [`${componentCls}-content`]: {\n        position: 'relative'\n      }\n    }), generatorTooltipPresetColor(token)), {\n      // RTL\n      '&-rtl': {\n        direction: 'rtl'\n      }\n    })\n  },\n  // Arrow Style\n  getArrowStyle(mergeToken(token, {\n    borderRadiusOuter: tooltipRadiusOuter\n  }), {\n    colorBg: 'var(--antd-arrow-background-color)',\n    showArrowCls: '',\n    contentRadius: tooltipBorderRadius,\n    limitVerticalRadius: true\n  }),\n  // Pure Render\n  {\n    [`${componentCls}-pure`]: {\n      position: 'relative',\n      maxWidth: 'none'\n    }\n  }];\n};\n// ============================== Export ==============================\nexport default ((prefixCls, injectStyle) => {\n  const useOriginHook = genComponentStyleHook('Tooltip', token => {\n    // Popover use Tooltip as internal component. We do not need to handle this.\n    if (injectStyle === false) {\n      return [];\n    }\n    const {\n      borderRadius,\n      colorTextLightSolid,\n      colorBgDefault,\n      borderRadiusOuter\n    } = token;\n    const TooltipToken = mergeToken(token, {\n      // default variables\n      tooltipMaxWidth: 250,\n      tooltipColor: colorTextLightSolid,\n      tooltipBorderRadius: borderRadius,\n      tooltipBg: colorBgDefault,\n      tooltipRadiusOuter: borderRadiusOuter > 4 ? 4 : borderRadiusOuter\n    });\n    return [genTooltipStyle(TooltipToken), initZoomMotion(token, 'zoom-big-fast')];\n  }, _ref => {\n    let {\n      zIndexPopupBase,\n      colorBgSpotlight\n    } = _ref;\n    return {\n      zIndexPopup: zIndexPopupBase + 70,\n      colorBgDefault: colorBgSpotlight\n    };\n  });\n  return useOriginHook(prefixCls);\n});"],"mappings":";AAAA,SAASA,cAAc,QAAQ,oBAAoB;AACnD,SAASC,qBAAqB,EAAEC,UAAU,EAAEC,YAAY,QAAQ,sBAAsB;AACtF,SAASC,cAAc,QAAQ,aAAa;AAC5C,OAAOC,aAAa,IAAIC,2BAA2B,QAAQ,4BAA4B;AACvF,IAAMC,2BAA2B,GAAG,SAA9BA,2BAA2B,CAAGC,KAAK,EAAI;EAC3C,IACEC,YAAY,GACVD,KAAK,CADPC,YAAY;EAEd,OAAON,YAAY,CAACO,MAAM,CAAC,UAACC,aAAa,EAAEC,YAAY,EAAK;IAAA;IAC1D,IAAMC,UAAU,GAAGL,KAAK,WAAII,YAAY,QAAK;IAC7CD,aAAa,YAAKF,YAAY,cAAIG,YAAY,EAAG,+EAC3CH,YAAY,aAAW;MACzBK,eAAe,EAAED;IACnB,CAAC,mDACGJ,YAAY,aAAW;MACzB,+BAA+B,EA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